package cn.com.biz;

import java.util.List;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import cn.com.dao.YuYueDao;
import cn.com.entity.YuYue;


public class YuYueBiz {
	private YuYueDao yuyueDao;
	public YuYueDao getYuyueDao() {
		return yuyueDao;
	}

	public void setYuyueDao(YuYueDao yuyueDao) {
		this.yuyueDao = yuyueDao;
	}
	
	public List<YuYue> ckyuyue(){
		ApplicationContext ctx=new ClassPathXmlApplicationContext("appliactionContext.xml");
		yuyueDao=(YuYueDao)ctx.getBean("yuyueDao");
		List<YuYue> yylist=yuyueDao.ckyuyue();
		return yylist;
	}
	public boolean insertyuyue(YuYue yuyue){
		boolean b=yuyueDao.insertyuyue(yuyue);
		return b;
	}
	public boolean deleteyuyue(int id){
		boolean b=yuyueDao.deleteyuyue(id);
		return b;
	}
	public List<YuYue> getuserid(int userid){
		List<YuYue> yhlist=yuyueDao.getuserid(userid);
		return yhlist;
	}
	public List<YuYue> getyishengid(int yishengid){
		List<YuYue> yslist=yuyueDao.getyishengid(yishengid);
		return yslist;
	}
	
}
